package com.springboot.dense.mapper;

import com.springboot.dense.dto.FogLevelDTO;
import com.springboot.dense.entity.FogLevel;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.springboot.dense.vo.*;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author ${author}
 * @since 2021-04-14
 */
public interface FogLevelMapper extends BaseMapper<FogLevel> {

    List<FogLevelDTO> findByAll();

    List<FogLevelDTO> findByone(@Param("id")int id);

    List<FogLevelDTO> findsearchCity(@Param("city")String city);

    List<FogLevelDTO> findsearchLevel(@Param("level")int level);

    List<FogLevelDTO> findsearchAll(@Param("city")String city,@Param("level")int level);

    List<CityAlertVO> findCityAlertByDate(@Param("date")String date);

    List<CityHistoryLevelVO> findCityHistoryLevel();

    List<CityLastWeekLevelVO> findCityLastWeekLevel(@Param("city") String city);

    //这个方法是第二个页面所用
    List<CityHistoryDetailVO> findCityLastWeekLevelTwo(@Param("city") String city);

    CityDetailVO findOneCityDetail(@Param("date")String date, @Param("city") String city);

}
